package com.tongtong.stsuserapi.service.base;

import com.tongtong.stscommon.message.STSMessage;

import java.util.List;

/**
 * 订单业务层
 */
public interface OrderService {

	/** 预定商品 */
	STSMessage createOrder(Long userid, Long itemId, Integer quantity);

	/** 取消订单 */
	STSMessage cancelOrder(Long userid, Long orderId, String reason);

	/** 完成订单 */
	STSMessage completeOrder(Long userid, Long orderId);

	/** 删除订单 */
	STSMessage deleteOrder(Long userid, Long orderId);

	/** 获取订单列表 */
	STSMessage getOrderList(Long userid, Integer orderState, Integer page, Integer pageSize);

	/** 获取订单详情 */
	STSMessage getOrderInfo(Long userid, Long orderId);

	/** 搜索订单 */
	STSMessage searchOrder(Long userid, String keyword, Integer orderState, Integer page, Integer pageSize);

	/** 批量预定购物车中的商品 */
	STSMessage createOrdersFromShoppingcart(Long userid, List<Long> shoppingcartIds);
}
